const db = uniCloud.database()
exports.main = async (event, context) => {
	//event为客户端上传的参数
	let {id, time, title, fileUrl} = event;

	return await db.collection("share-img").add({
		userid: id,
		posttime: time,
		data:{
			title,
			fileUrl
		}
	})
};
